package com.guodi.map.service.impl;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.guodi.map.entity.MapProjectAuth;
import com.guodi.map.mapper.MapProjectAuthMapper;
import com.guodi.map.service.IMapProjectAuthService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @描述：专题图层认证表 服务类
 * @作者: 代鹏刚
 * @日期: 2020-01-14
 */
@Service
@Slf4j
public class MapProjectAuthServiceImpl extends ServiceImpl<MapProjectAuthMapper, MapProjectAuth> implements IMapProjectAuthService {

    @Override
    public void removeByMaps(String roleId,String projectId,String[] orgIds) {
        this.baseMapper.removeByMaps(roleId, projectId,orgIds);
    }

    @Override
    public List<MapProjectAuth> getProjectByRoleIds(String[] roleIds) {
        return this.baseMapper.getProjectByRoleIds(roleIds);
    }

    @Override
    public void deleteByIds(String[] ids) {
        this.baseMapper.deleteByIds(ids);
    }

    @Override
    public List<MapProjectAuth> getSpecialSet(Page page, List<String> roleId) {
        log.info("roleId={}",roleId);
        return this.baseMapper.getSpecialSet(page,roleId);
    }
}